package core.util;

import org.apache.commons.jxpath.JXPathContext;

public class JxpathMacroVariableContainer implements MacroVariableContainer {
 
    private JXPathContext jxpathContext = null;
    
    public JxpathMacroVariableContainer(Object bean) {
        jxpathContext = JXPathContext.newContext( bean );
        jxpathContext.setLenient( true );
    }
    public void setMacroVariable(String name, Object value) {
    }

    public void removeMacroVariable(String name) {
    }

    public Object getMacroVariable(String name) {
        return jxpathContext.getValue(name);
    }

}
